﻿using System;
using System.Collections.Generic;
using System.Data.SqlClient;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

public class clsMethods
{
    public static List<T> ConvertToList<T>(SqlDataReader sqldr, int index)
    {
        List<T> list = new List<T>();

        while (sqldr.Read())
        {
            list.Add((T)sqldr.GetValue(index));
            //index++;
        }

        return list;
    }
}
